package com.fpost.dao;

import java.io.Serializable;
import java.util.List;

import org.hibernate.SessionFactory;

import com.fpost.hibernate.util.HibernateSessionFactory;

public abstract class GenericDAO<T> {

	public SessionFactory getSessionFactory() {
		return HibernateSessionFactory.getInstance().getSessionFactory();
	}
	
	public abstract Serializable save(T t);
	
	public abstract void saveOrUpdate(T t);

	public abstract void delete(long id);
	
	public abstract void delete(T t);

	public abstract T get(long id);	

}
